import { tableColumns } from './data'

export function useColumns() {
  const getColumns = (column, record) => {
    if (column.dataIndex === 'productName') {
      return <span>{record.productName}</span>
    } else if (column.dataIndex === 'productDate') {
      return <span>{record.productDate}</span>
    } else if (column.dataIndex === 'actualLocationName') {
      return <span>{record.actualLocationName}</span>
    } else if (column.dataIndex === 'productNumber') {
      return <span>{record.productNumber}</span>
    }
  }
  return {
    getColumns,
    tableColumns
  }
}
